package com.hyxf;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.core.env.Environment;

/**
 * @author 阿紫
 * @version 1.0.1
 * @project spring-ai-helloworld
 * @description
 * @date 2025/5/23 15:06:12
 */
@SpringBootApplication
public class AiApplication {

    public static void main(String[] args) {
        ConfigurableApplicationContext application = SpringApplication.run(AiApplication.class, args);
        Environment env = application.getEnvironment();
        String port = env.getProperty("server.port");
        System.out.println("==============AiApplication启动成功，服务端口为：" + port);

    }
}
